package org.example;

import org.example.utils.RocketMqUtil;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import javax.annotation.Resource;

/**
 * Hello world!
 *
 */
@SpringBootApplication
public class App implements CommandLineRunner {
    public static void main( String[] args ) {
        SpringApplication.run(App.class, args);
    }

    @Resource
    RocketMqUtil rocketMqUtil;

    @Override
    public void run(String... args) throws Exception {
        rocketMqUtil.sendAsyncMsg("test-topic", "hello world");
    }


}
